package org.example.easybuy.dao;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.example.easybuy.entity.UserAddress;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface UserAddressDao {
    int addUserAddress(UserAddress userAddress);
    List<UserAddress> selectAddressByLoginName(String loginName);
    int delAddress(int id);
    int changeDefault(int id);
    int changeNoDefault(@Param("id")int id,@Param("userId")int userId);
    int updateUserAddress(UserAddress userAddress);
}
